Skip to content
This repository has been archived by the owner on Feb 26, 2024. It is now read-only.

ci: remove docker from automated release workflow #3547

Merged
merged 29 commits into from
Aug 23, 2022

Conversation

MicaiahReid
Copy link
Contributor

@MicaiahReid MicaiahReid commented Aug 16, 2022

Previously our automated release process would require successfully publishing to Docker to complete. Since publishing to Docker can sometimes be unreliable, this would occasionally cause the release to fail, meaning we'd have to manually fix our release process' commit history and publish to Docker.

This change moves the step to publish to Docker to its own action, which is run only if the actual release is fully successful. Because this is now a separate job in the release process, we can rerun that individual job if it fails.

Fixes #3546.

@MicaiahReid
Copy link
Contributor Author

Notes for reviewers:

CI stuff is always weird to test. Here were the steps that I took.

Testing the new action

I created a temporary test-publish-action.yml (removed in e7929ef) that would run the new action every time I pushed to the branch. With this, I was able to test calling the action and making sure I was passing/using the inputs to the action correctly. With some finagling, I was able to call the Docker publish action succesffully.

Since we don't want to actually publish to Docker, I didn't let the step complete. However, I let it run deep into the process before cancelling. This run can be found here.

Testing dependent jobs

We also want to be sure that the new release action still works, and that the action will successfully be called when the release completes. If you look at the diff of the release.yml, I've mainly removed stuff and added the dependent publish-docker job.

To test the dependency, I commented out most of the meaningful code in the release job, and the actual calling of the new action in publish-docker job (calling this job was copied verbatim from my above test using test-publish-action.yml. All that should happen with these commented out jobs is: 1. release runs npm ci 2. once the release is finished, publish-docker would checkout the branch. This can be seen working here. Note that the publish-docker job can be rerun independently if it fails.

Summary

My goal with the above tests was to prove that the new action can successfully publish to docker, that we are correctly calling this new action from the release job, and that the release job no longer relies on the publish-docker job to finish the release.

Let me know if there are more tests you'd like to see to feel comfortable with this.

Copy link
Member

@davidmurdoch davidmurdoch left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

<3

.github/actions/docker-publish/action.yml Outdated Show resolved Hide resolved
.github/actions/docker-publish/action.yml Outdated Show resolved Hide resolved
.github/actions/docker-publish/action.yml Outdated Show resolved Hide resolved
.github/actions/docker-publish/action.yml Outdated Show resolved Hide resolved
.github/actions/docker-publish/action.yml Outdated Show resolved Hide resolved
.github/actions/docker-publish/action.yml Outdated Show resolved Hide resolved
.github/actions/docker-publish/action.yml Outdated Show resolved Hide resolved
.github/actions/docker-publish/action.yml Show resolved Hide resolved
Copy link
Member

@davidmurdoch davidmurdoch left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lol

.github/actions/docker-publish/action.yml Outdated Show resolved Hide resolved
.github/actions/docker-publish/action.yml Outdated Show resolved Hide resolved
.github/actions/docker-publish/action.yml Outdated Show resolved Hide resolved
Copy link
Member

@davidmurdoch davidmurdoch left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yay

@MicaiahReid MicaiahReid merged commit 591d025 into develop Aug 23, 2022
@MicaiahReid MicaiahReid deleted the move-docker-release branch August 23, 2022 20:52
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

remove docker publish from automated release workflow
3 participants